package com.scy.boot06test02.mapper;


import com.scy.boot06test02.entity.UserInfo;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
//持久层的接口
@Mapper
public interface UserMapper {
    @Select("select password from userinfo where username=#{username}")
    UserInfo selectByUsername(String username);

    @Insert("insert into userinfo values(null,#{username},#{password},#{nickname},#{age})")
    void insert(UserInfo userInfo);
}
